package com.minsf.rpc.fault.retry;

import com.minsf.rpc.model.RpcResponse;

import java.util.concurrent.Callable;

/**
 * @Description 不重试策略
 * @Author minify
 * @Date 2024/3/31 20:50
 * @Project sf-rpc
 */
public class NoRetryStrategy implements RetryStrategy {

    /**
     * 重试
     * @param callable
     * @return
     * @throws Exception
     */
    @Override
    public RpcResponse doRetry(Callable<RpcResponse> callable) throws Exception {
        return callable.call();
    }
}
